#/bin/bash

dr=
remote=
branch=master
Usage="请传递正确的参数，Usage:./git.init.sh -d /dir/ -r ssh:git.com/gitlib"

while getopts "r:d:b" arg
do
    case $arg in
      r)
        remote=$OPTARG
	;;	
      d)
        dr=$OPTARG
     	;;
      b)
	branch=$OPTARG
	;;	
    esac
done


if [ "$dr" = "" ]
then
  echo $Usage
  exit
fi

if [ "$remote" = "" ]
then
  echo $Usage
  exit
fi




git clone $remote $dr
